cumsum — Cumulative Summation
cumsum
takes a matrix argument, and produces another matrix
of the same dimensions. Each element in the resultant matrix consists
of the cumulative sum of the that element and all previous elements
in that column of the argument matrix. If the argument is either a row
or column vector, the cumulative summation is performed on that row or
column.
This is not an built-in function. This function
is normally loaded on start-up from the cumsum.r
file in the
standard rlib
directory. Use of the -r
option, incorrectly
setting the RLAB_LIB_DIR
environmental variable, or modifying
cumsum.r
may make this function unavailable.
Subsections